/**
 * 
 */
package com.nari.interfaces.decipher.gprs.vo;

/**
 * 
 * @author Xiaopeng
 * @date 2015-2-6
 */
public class ClientHost {
	private String ip;
	private int port;
	
	/**
	 * 客户端主机实体封装
	 * @param ip
	 * @param port
	 * @return
	 * @author Xiaopeng
	 * @date 2015-2-6
	 */
	public static ClientHost getInstance(String ip, int port) {
		ClientHost clientHost = new ClientHost();
		clientHost.setIp(ip);
		clientHost.setPort(port);
		return clientHost;
	}
	
	/**
	 * 覆盖实体toString方法
	 * @return
	 * @author Xiaopeng
	 * @date 2015-2-6
	 */
	public String toString() {
		return ip + ":" + port;
	}

	/**
	 * @return the ip
	 */
	public String getIp() {
		return ip;
	}

	/**
	 * @param ip the ip to set
	 */
	public void setIp(String ip) {
		this.ip = ip;
	}

	/**
	 * @return the port
	 */
	public int getPort() {
		return port;
	}

	/**
	 * @param port the port to set
	 */
	public void setPort(int port) {
		this.port = port;
	}
	
}
